load("@com_github_bazelbuild_buildtools//buildifier:def.bzl", "buildifier")

buildifier(
    name = "buildifier",
    diff_command = "diff -u --color",
    exclude_patterns = [
        "//cc/third_party",
        "./external/*",
    ],
    lint_mode = "warn",
    lint_warnings = [
        "-module-docstring",
        "-module-docstring-header",
        "-function-docstring",
        "-function-docstring-header",
        "-function-docstring-args",
    ],
    mode = "diff",
)

buildifier(
    name = "buildifier-fix",
    diff_command = "diff -u --color",
    exclude_patterns = [
        "//cc/third_party",
        "./external/*",
    ],
    lint_mode = "fix",
    lint_warnings = [
        "-module-docstring",
        "-module-docstring-header",
        "-function-docstring",
        "-function-docstring-header",
        "-function-docstring-args",
    ],
    mode = "fix",
)

filegroup(
    name = "data",
    srcs = glob([
        "data/**/*",
    ]),
    visibility = ["//visibility:public"],
)
